<div class="layui-form" lay-filter="LAY-home-admin-adminform-form" id="LAY-home-admin-adminform-form" style="padding: 20px 30px 0 0;">
    <div class="layui-form-item">
        <label class="layui-form-label">用户名(邮箱)</label>
        <div class="layui-input-inline">
            <script type="text/html" template>
                <input type="text" name="user_name" value="{{ d.params.user_name || '' }}" lay-verify="required|email"
                       placeholder="请输入邮箱地址" autocomplete="off" class="layui-input">
            </script>
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">身份</label>
        <div class="layui-input-inline">
            <script type="text/html" template>
                <select name="agency_id">
                    <option value="0" {{ d.params.agency_id== 0 ?
                    'selected' : '' }}>系统管理员</option>
                    <option value="1" {{ d.params.agency_id==
                            1 ?
                    'selected' : '' }}>普通管理员</option>
                </select>
            </script>
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">手机</label>
        <div class="layui-input-inline">
            <script type="text/html" template>
                <input type="text" name="phone" value="{{ d.params.phone || '' }}" lay-verify="phone"
                       placeholder="请输入号码" autocomplete="off" class="layui-input">
            </script>
        </div>
    </div>
    <script type="text/html" template>
        {{# if(d.params.event != 'edit'){ }}
        <div class="layui-form-item">
            <label class="layui-form-label">密码</label>
            <div class="layui-input-inline">
                <input type="password" name="password" value="{{ d.params.password || '' }}" lay-verify="password"
                       placeholder="请输入密码" autocomplete="off" class="layui-input"
                       lay-affix="eye"
                >
            </div>
        </div>
        {{# } }}
        <input type="hidden" name="user_id" value="{{ d.params.user_id }}">
    </script>

    <div class="layui-form-item">
        <label class="layui-form-label"></label>
        <div class="layui-input-inline">
            <input type="button" lay-submit lay-filter="LAY-home-admin-adminform-form-submit" value="确认" class="layui-btn">
        </div>
    </div>
</div>

<script>
    layui.use(['admin', 'form'], function () {
        var $ = layui.$
            , form = layui.form;

    });
</script>